﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Music.Master" Inherits="System.Web.Mvc.ViewPage<music.Models.GenreViewModel>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    Index
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <h3>
        Genre</h3>
    <br />
    Total Genre Count :
    <%=Model.GenreCount %>
    <table>
        <tr>
            <td>
                Id
            </td>
            <td>
                Name
            </td>
            <%--<td>
                Description
            </td>--%>
        </tr>
        <%
            foreach (var genre in Model.Genres)
            {
        %>
        <tr>
            <td>
                <%:genre.GenreId %>
            </td>
            <td>
                <%--<a href='/store/BrowseAlbum?genre=<%:genre.Name %>' ><%:genre.Name %></a>--%>
                <%: Html.ActionLink(genre.Name, "BrowseAlbum", new { genre = genre.Name })%>
            </td>
            <%-- <td>
                <%:genre.Description %>
            </td>--%>
        </tr>
        <%
            }
        %>
    </table>
</asp:Content>
